﻿<%@ Page Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<WsusWebAdmin.Web.Wsus.WsusHostData>>" %>

<asp:Content ID="loginTitle" ContentPlaceHolderID="TitleContent" runat="server">
    Login
</asp:Content>
<asp:Content ID="loginContent" ContentPlaceHolderID="MainContent" runat="server">
    <h2>
        Login</h2>
    <p>
        Enter your username and password
    </p>
    <%= Html.ValidationSummary("Login failed") %>
    <% using (Html.BeginForm()) { %>
    <div>
        <fieldset>
            <p>
                <label for="host">WSUS host:</label>
                <%=Html.DropDownList("host",Model.Select(x=>new SelectListItem
                       {
                        Value=x.Name,
                        Text=x.Name
                       }))%>
                <%= Html.ValidationMessage("host") %>
            </p>
            <p>
                <label for="username">
                    Username:</label>
                <%= Html.TextBox("username") %>
                <%= Html.ValidationMessage("username") %>
            </p>
            <p>
                <label for="password">
                    Password:</label>
                <%= Html.Password("password") %>
                <%= Html.ValidationMessage("password") %>
            </p>
            <p>
                <input type="submit" value="Login" />
            </p>
        </fieldset>
    </div>
    <% } %>
</asp:Content>
